<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
	<head>
		<title>Mont Blanc Foot F7 - Dar de Alta Jugadores</title>

		<?php
		$this -> load -> model('Torneo_Model');
		$this -> load -> view('head_view');
		?>
	</head>
	<body id="page1">
		<div id="line-hor-create">
		</div>
		<div id="main-bg-top">
			<div id="main-bg-bot">
				<div id="main">
					<!-- header -->
					<div id="header">
						<?php $this -> load -> view('league_header');?>
					</div>
					<!-- content -->
					<div id="content">
						<!-- script -->
						<div id="indent">
							<!-- scrolFler news -->
							<h1>Equipos por torneo</h1>
							</br>
							<?php foreach($tournaments as $row) {
							?>
							<h2>
							<?php echo $row -> tournament_name;?>
							</h2>
							<table class='admin1'>
								<?php $teams = $this -> Torneo_Model -> get_teams_on_tournament($row -> tournament_id); foreach ($teams as $team ) {
								?>
								<tr>
									<td>
									<?php echo $team -> team_name;?>
									</td>
									<td>
									<a class="ui-avena-button ui-state-default ui-corner-all" href="#">
									<span class="ui-icon ui-icon-contact"></span>
									Remover equipo
									</a>
									</td>
									<td>
									<a class="ui-avena-button ui-state-default ui-corner-all" href="/index.php/teams/edit/<?php echo $team -> team_id;?>">
									<span class="ui-icon ui-icon-contact"></span>
									Editar Equipo
									</a>
									</td>
								</tr>
								<?php }?>
							</table>
							<?php }?>
							<!--
							<div id="flexform">
							<h1>Datos Guardados con &Eacute;xito</h1>
							<p>
							<h1>
							<a href="/index.php/<?php //echo $url;?>"> << Atras </a>
							</h1>
							</p>
							</div>
							-->
							<div class="wrapper">
								<div id="column-left">
									<!-- Latest players added to league -->
									<!-- Team Administration -->
								</div>
							</div>
						</div>
					</div>
					<!-- footer -->
					<div id="footer">
						<?php $this -> load -> view('league_footer');?>
					</div>
				</div>
			</div>
		</div>
	</body>
</html>
